Skip to content

.NET: feat: adds the executorId as an additional property when running the workflow as agent in dotnet - #7934

Open
Vincent Biret (baywet) wants to merge 16 commits into
mainfrom
feat/workflow-as-agent-executor-id-dotnet
Open

Vincent Biret (baywet) wants to merge 16 commits into
mainfrom
feat/workflow-as-agent-executor-id-dotnet

Conversation

@baywet

Copy link
Copy Markdown
Member

fixes #4445

Copilot AI balanced review requested due to automatic review settings August 28, 2026 12:53
@agent-framework-automation agent-framework-automation Bot added .NET Usage: [Issues, PRs], Target: .Net workflows Usage: [Issues, PRs], Target: Workflows labels Aug 28, 2026
@github-actions github-actions Bot changed the title feat: adds the executorId as an additional property when running the workflow as agent in dotnet .NET: feat: adds the executorId as an additional property when running the workflow as agent in dotnet Aug 28, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds workflow executor attribution to streamed .NET agent response updates.

Changes:

  • Adds a public executorId metadata key.
  • Attaches executor IDs to response updates.
  • Adds multi-executor streaming coverage.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
WorkflowAgentAdditionalProperties.cs Defines the executor ID key.
AgentResponseUpdateEvent.cs Adds attribution metadata to updates.
WorkflowHostSmokeTests.cs Tests attribution and metadata preservation.

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
github-actions[bot]

This comment was marked as outdated.

This comment was marked as outdated.

…cross execution methods

Signed-off-by: Vincent Biret <vibiret@microsoft.com>
…revious inputs for the executorId

Signed-off-by: Vincent Biret <vibiret@microsoft.com>
Signed-off-by: Vincent Biret <vibiret@microsoft.com>
/// <summary>
/// Defines additional property keys used by workflow-hosted agents.
/// </summary>
public static class WorkflowAgentAdditionalProperties

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI: If we are unsure about something new that is public we often mark it as experimental, to make sure we can still make changes to it before graduating the feature. We then remove experimental once we are happy with the overall change.
Not sure if that is applicable here, but just an FYI.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks I think Tao Chen (@TaoChenOSU) and Peter Ibekwe (@peibekwe) will be able to inform the design here and whether or not we need to add those experimental aspects.

@baywet

Copy link
Copy Markdown
Member Author

worth exploring this instead of magic keys in a dictionary

update.RawRepresentation is ExecutorEvent exevt
exevt.ExecutorId

@github-code-quality

github-code-quality Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Code coverage overview

Languages: C#

C# / code-coverage/dotnet

main 908ed6f feat/workflow-as-age... 48161c0 +/-
86% 86% 0%
View coverage of the 5 most impacted files.
File main 908ed6f feat/workflow-as-age... 48161c0 +/-
/home/runner/wo...SessionStore.cs 100% 56% -44%
/home/runner/wo...Mem0Provider.cs 100% 100% 0%
/home/runner/wo...kflowSession.cs 87% 88% +1%
/home/runner/wo...eUpdateEvent.cs 73% 83% +10%
/home/runner/wo...esponseEvent.cs 67% 80% +13%

ℹ️ Calculations represent line coverage. Results may change as calculations are updated.


Updated October 29, 2026 14:51 UTC

…t-executor-id-dotnet

# Conflicts:
#	dotnet/src/Microsoft.Agents.AI.Workflows/PublicAPI/net10.0/PublicAPI.Unshipped.txt
#	dotnet/src/Microsoft.Agents.AI.Workflows/PublicAPI/net472/PublicAPI.Unshipped.txt
#	dotnet/src/Microsoft.Agents.AI.Workflows/PublicAPI/net8.0/PublicAPI.Unshipped.txt
#	dotnet/src/Microsoft.Agents.AI.Workflows/PublicAPI/net9.0/PublicAPI.Unshipped.txt
#	dotnet/src/Microsoft.Agents.AI.Workflows/PublicAPI/netstandard2.0/PublicAPI.Unshipped.txt

Co-authored-by: baywet <7905502+baywet@users.noreply.github.com>

This branch was previously deployed

2 inactive deployments
integration — 48161c04 Deployed Oct 29, 2026 by Copilot via dotnet-foundry-hosted-it #31577
github-app-auth — 48161c04 Deployed Oct 29, 2026 by Copilot via add_label #26525
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

.NET Usage: [Issues, PRs], Target: .Net workflows Usage: [Issues, PRs], Target: Workflows

Projects

None yet

Development

Successfully merging this pull request may close these issues.

.NET: [Feature]: Expose ExecutorId for AgentResponseUpdate when using workflow\.AsAgent().RunStreamingAsync()

5 participants